package git.determinal.template.view;




import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
import io.swagger.annotations.ApiModel;
import java.util.ArrayList;
import java.util.Collection;




import java.util.ArrayList;
import java.util.List;

public class OrderFields {
    public OrderFields() {
    }

    public static class Builder {
        private List<OrderField> orderFields;

        public Builder() {
        }

        public static OrderFields.Builder builder() {
            return new OrderFields.Builder();
        }

        public OrderFields.Builder addOrder(OrderField orderField) {
            if (this.orderFields == null) {
                this.orderFields = new ArrayList();
            }

            this.orderFields.add(orderField);
            return this;
        }

        public OrderFields.Builder addOrder(String field, OrderType orderType) {
            return this.addOrder(OrderField.of(field, orderType));
        }

        public OrderFields.Builder addOrder(String field) {
            return this.addOrder(OrderField.of(field));
        }

        public List<OrderField> build() {
            return this.orderFields;
        }
    }
}

